dubbo测试页面
<script type="text/javascript" src="/lib/jquery/jquery-3.1.1.min.js"></script>
<table style="width: 90%">
    <tr>
        <td>
            注册中心地址:
            <input id ="address" value="${address!}">
        </td>
    </tr>
    <tr>
        <td>
            接口名称:
            <input id="interfaceName">
        </td>
    </tr>
    <tr>
            <td>
            ip端口:
                <select id="ip" style="width: 300px">

                </select>
            </td>
    </tr>
    <tr>
            <td>
                方法名:
                <select id="methodName" style="width: 300px">

                </select>
            </td>
        <td>
            编码:
                <select id="encoding" style="width: 300px">
                    <option value="UTF-8">UTF-8</option>
                    <option value="GBK">GBK</option>
                </select>
        </td>
    </tr>
    <Tr>
        <td>
            <button style="width: 50px;height: 50px" value="解析ip" onclick="resolveIp()">解析ip</button>
            <button style="width: 50px;height: 50px" value="解析ip" onclick="resolveMethod()">解析方法</button>
            <button style="width: 50px;height: 50px" value="解析ip" onclick="invoke()">执行调用</button>
        </td>
    </Tr>
</table>
<table>
    <Tr>
        <Td>
            <textarea id="param" style="width: 500px;height: 400px"></textarea>
        </Td>
        <Td>
            <div id="result"></div>
        </Td>
    </Tr>
</table>
<script type="text/javascript">
    function invoke() {
        var url ="/dubbo/invoke";
        var ip=$("#ip").val();
        var interfaceName =$("#interfaceName").val();
        var methodName =$("#methodName").val();
        var param =$("#param").val();
        var encoding=$("#encoding").val()
        $.ajax({
            url:url,
            method:"post",
            // dataType:"json",
            data:{
                ip:ip,
                interfaceName:interfaceName,
                methodName:methodName,
                param:param,
                encoding:encoding
            },
            beforeSend:function(){
                $("#methodName").empty();
            },success:function(result){
               $("#result").text(result)
            }
        })
    }
    function resolveMethod(){
        var url ="/dubbo/resolveMethod";
        var ip=$("#ip").val();
        var interfaceName =$("#interfaceName").val();
        $.ajax({
            url:url,
            method:"post",
            // dataType:"json",
            data:{
                ip:ip,
                interfaceName:interfaceName
            },
            beforeSend:function(){
                $("#methodName").empty();
            },success:function(result){
                for(var i=0;i<result.length;i++){
                    var option ="<option value='"+result[i]+"'>"+result[i]+"</option>";
                    $("#methodName").append(option)
                }
            }
        })
    }
    function resolveIp(){
        var url ="/dubbo/resolveIp";
        var address =$("#address").val();
        var interfaceName =$("#interfaceName").val();
        $.ajax({
            url:url,
            method:"post",
            // dataType:"json",
            data:{
                address:address,
                interfaceName:interfaceName
            },
            success:function(result){
                for(var i=0;i<result.length;i++){
                    var option ="<option value='"+result[i]+"'>"+result[i]+"</option>";
                    $("#ip").append(option)
                }
            }
        })
    }


</script>

<style type="text/css">
    input{
        width: 400px;
    }
</style>